#ifndef EVENTWIN_H
#define EVENTWIN_H

#include <QWidget>
#include <QMouseEvent>
#include <QKeyEvent>
#include <QPaintEvent>
#include <QTimerEvent>
#include "custombutton.h"
namespace Ui {
class EventWin;
}

class EventWin : public QWidget
{
    Q_OBJECT

public:
    explicit EventWin(QWidget *parent = 0);
    ~EventWin();
protected:
    void mousePressEvent(QMouseEvent *event);
    void mouseMoveEvent(QMouseEvent* event);
    void keyPressEvent(QKeyEvent* event);
    void paintEvent(QPaintEvent* event);
    void timerEvent(QTimerEvent * e);

private slots:
    void on_cricleButton_clicked();

    void on_squreButton_clicked();

private:
    Ui::EventWin *ui;
    int flag = 1;
    int timeId100;
    int timeId1000;

    CustomButton *custButton;
};

#endif // EVENTWIN_H
